import { createRouter, createWebHashHistory, RouteRecordRaw } from 'vue-router'
import Dingdan from "../views/dingdan/index.vue"
const routes: Array<RouteRecordRaw> = [
{
      path: '/',
      name: '首页',
      component: () => import('@/views/shouye/index.vue')
    },
    {
      path: '/dingdan',
      name: '订单',
      component:Dingdan,
      children:[
        {
          path:"",
          component:()=>import('@/views/dingdan/component/allOrder.vue'),
        },
        {
          path:"allOrder",
          component:()=>import('@/views/dingdan/component/allOrder.vue'),
        },
        {
          path:"evaluated",
          component:()=>import('@/views/dingdan/component/evaluated.vue'),
        },
        {
          path:"refund",
          component:()=>import('@/views/dingdan/component/refund.vue'),
        },
      ]
    },
    {
      path: '/wode',
      name: '我的',
      component: () => import('@/views/wode/index.vue')
    },
    {
      path: '/mthb',
      name: '美团红包',
      component: () => import('@/views/wode/mthb.vue')
    },
    {
      path: '/zml',
      name: '赚米粒',
      component: () => import('@/views/wode/zml.vue')
    },
    {
      path: '/xgsjhm',
      name: '修改手机号码',
      component: () => import('@/views/wode/xgsjhm.vue')
    },
    {
      path: '/wddz',
      name: '我的地址',
      component: () => import('@/views/wode/wddz.vue')
    },
    {
      path: '/sjdjq',
      name: '商家美团代金券',
      component: () => import('@/views/wode/sjdjq.vue')
    },
    {
      path: '/wdqb',
      name: '我的钱包',
      component: () => import('@/views/wode/wdqb.vue')
    },
    {
      path: '/wdsc',
      name: '我的收藏',
      component: () => import('@/views/wode/wdsc.vue')
    },
    {
      path: '/wdpj',
      name: '我的评价',
      component: () => import('@/views/wode/wdpj.vue')
    },
    {
      path: '/jt',
      name: '津贴',
      component: () => import('@/views/wode/jt.vue')
    },
    {
      path: '/fpzs',
      name: '发票助手',
      component: () => import('@/views/wode/fpzs.vue')
    },
    {
      path: '/cyjm',
      name: '餐饮加盟',
      component: () => import('@/views/wode/cyjm.vue')
    },
    {
      path: '/xyhsm',
      name: '协议和说明',
      component: () => import('@/views/wode/xyhsm.vue')
    },
    {
      path: '/kfzx',
      name: '客服中心',
      component: () => import('@/views/wode/kfzx.vue')
    },
    {
      path: '/yqyj',
      name: '邀请有奖',
      component: () => import('@/views/wode/yqyj.vue')
    },
    {
      path: '/qydc',
      name: '企业订餐',
      component: () => import('@/views/wode/qydc.vue')
    },
  {
      path: '/fenlei',
      name: '分类',
      component: () => import('@/views/fenlei/index.vue')
    },
    {
      path: '/dianpu',
      meta:{
        name:"店铺"
      },
      component: () => import('@/views/dianpu/index.vue'),
    }

]

const router = createRouter({
  history: createWebHashHistory(),
  routes
})

export default router